﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.Mvc;
using TeleRad.Services;
using System.Security.Principal;
using TeleRad.Models;

namespace TeleRad.Controllers
{
    [Authorize]
    public class HomeController : Controller
    {
        private IContentService _ContentService;
        
        public HomeController(IContentService ContentService)
        {
            this._ContentService = ContentService;
        }
        
        public ActionResult Index()
        {
            return View(_ContentService.GetProfile());
        }

        public ActionResult Picture()
        {
            var paths = _ContentService.GetImagesPath();
            return View(paths);
        }

        public ActionResult Video()
        {
            var paths = _ContentService.GetVideosPath();
            return View(paths);
        }

        public ActionResult Report()
        {
            var path = _ContentService.GetReportsPath();
            return View(path);
        }

        public ActionResult About()
        {
            return View();
        }

        [ChildActionOnly]
        public ActionResult PatientInformation()
        {
            return PartialView(_ContentService.GetProfile());
        }
    }
}
